<extend name="Base:common" />
<block name="static">
<link rel="stylesheet" href="__CSS__/index.css" />
</block>
<block name="body">
	<!--加载广告start-->
	<div class="wst-ad">
		<div class="wst-slide" id="wst-slide">
			<ul class="wst-slide-items">
				<volist name="indexAds" id="vo" key="k">
				<li style="z-index: 1;"><a target="_blank" onclick="addAccess({$vo['adId']})" href="{$vo['adURL']}">
						<img src="__ROOT__/{$vo['adFile']}" height="360" width="100%" title="{$vo['adName']}" />
				</a></li>
				</volist>
			</ul>
		</div>
	</div>
	<div class='wst-clear'></div>
	<!--加载商品楼层start-->

	<!-------------F1层---------------->
	<div class="link">
		<h2>品牌街</h2>
	</div>
	<div class="lanmu">
	<volist name="indexBrands" key="k1" id="vo1">
		<div class="lanmu_conten" style="background: url('{$vo1.brandIco}') no-repeat;background-size:260px 260px;">
			<a class="a_img" href="{:U('Home/Goods/getGoodsList/',array('brandId'=>$vo1['brandId']))}">
				<p>{$vo1["brandName"]}</p>
				<span style="overflow: hidden">{$vo1["brandDesc"]}</span>
			</a>
		</div>
	</volist>
	<div style="clear:both;"></div>
	<div class="lanmu_conten_x">
		<php>$num = 0;</php>
		<volist name="catList" key="k" id="vox">
		<volist name="vox['catChildren']" key="k2" id="vo2"> 
		<volist name="vo2['catChildren']" key="k3" id="vo3">
		<php>if($num==20)break;</php>
		<a href="{:U('Home/Goods/getGoodsList/',array('c1Id'=>$vox['catId'],'c2Id'=>$vo2['catId'],'c3Id'=>$vo3['catId']))}">
			<img src="__ROOT__/{$vo3['cateImg']} ">
			<p>{$vo3["catName"]}</p>
		</a>
		<php>$num++;</php>
		</volist>
		</volist>
		</volist>
	</div>
	</div>
	
	<div id="asd_line" name='asd_line' class="asd_line">
		<volist name="catAds" id="vo">
			<a href="{$vo['adURL']}" target="_blank"><img src="__ROOT__/{$vo['adFile']}" title="{$vo['adName']}"></a>
		</volist>
	</div>
	

	<div class="navleft">
<ul>
<volist name="catList" key="k1" id="vo1">
<a href="#asd_line" name="navleft_a" id="{$vo1['catId']}">
	<li><span class="navleft_icon navleft_icon{$k1}"></span>
	{$vo1['catName']}<em class="navleft_jiantou"></em></li>
</a>
</volist>
</ul>
</div>
<span id="outin" class="outin" onclick="outin(this.id);">菜单收起</span>
	<div >
	<volist name="catList" key="k1" id="vo1">
	<div class="shop" name="shop_{$vo1['catId']}" style="display: none;">
	<volist name="vo1['catChildren']" key="k2" id="vo2">
	<volist name="vo2['goods']" key="k3" id="vo3">
		<div class="shopconten">
			<a href="{:U('Home/Goods/getGoodsDetails/',array('goodsId'=>$vo3[goodsId]))}">
			<img src="__ROOT__/{$vo3['goodsThums']}" width="260" height="180" alt="">
			<p>{$vo3['goodsName']}</p>
			</a>
			<span class="shop_jiaqian">￥{$vo3['shopPrice']|number_format=2}</span>
			<em></em>
			<s>￥{$vo3['marketPrice']|number_format=2}</s>
		</div>
		</volist>
		</volist>
		<div style="clear:both;"></div>
	</div>
		</volist>
		</div>
		<script>
	
$(document).ready(function(){
		$(".shop:first").css('display','block');
		$("a[name='navleft_a']").click(function(){
			var ip_id = $(this).attr('id');
		    var ip_id = "div[name=shop_"+ip_id+"]";
			$(ip_id).css('display','block');
			$(ip_id).siblings().css('display','none');
		});
	})

function outin(id){
	var text = $('#'+id).text();
	var div = $('.navleft');
		div.toggle();
	if (text=='菜单收起') {
		$('#'+id).text('菜单展开');
	}else{
		$('#'+id).text('菜单收起');
	}
}
</script>
</block>
<block name="footer_static">
<script src="__JS__/index.js"></script>
<script src="__JS__/global.js" type="text/javascript"></script>
<script src="__JS__/goods.js" type="text/javascript"></script>
</block>

